There may be some difference in when the document is read from disk depending on whether transaction logging is enabled. However, this only increases or decreases your odds of a conflict with user editing. It's perfectly possible for a new version of a document to be saved by a user while your agent is working on it even if the document was just read from disk.
To avoid all chance of this occurring, you must use the Save argument that tests whether there is a save conflict and aborts the save. Something like this:
set nextdoc = coll.getnextdocument(doc)
Do
- ' do your document processing here.
savedOK = doc.Save(False, False)
if Not savedOK then ' probable save conflict.
- ' get the document out of memory and read it again from disk.
strTemp = doc.NoteID
delete doc
set doc = db.GetDocumentByID(strTemp)
set doc = nextdoc
Disclaimer: this is just off the top of my head; you probably should do something to prevent an infinite loop in case the save fails for some reason other than a user editing the document.


. . RE: Different behaviour of NotesDoc... (~Bill Frokimari... 9.Oct.03) 